import 'package:flutter/material.dart';

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {

  @override
  Widget build(BuildContext context) {
    return new MaterialApp(
      title: "Static Image Demo",
      theme: ThemeData.fallback(),

      // 写法一
      home: Image (
        image: AssetImage('images/icon.png'),
      ),

      // 写法二，两者等效
//      home: Image.asset('images/icon.png'),
    );
  }
}